package com.ustudy.entity.iden;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.ustudy.core.config.enums.Gender;
import org.ustudy.core.dao.support.entity.LongIdEntity;

import com.ustudy.entity.commons.PathFile;

/**
 * 注册用户
 * @author caizh
 *
 */
@SuppressWarnings("serial")
@Entity(name="RegUser")
@Table(name="IDEN_USER")
public class RegUser extends LongIdEntity {
	
	/**
	 * 基础信息
	 */
	private String loginName;
	private String nickName;
	private String password;
	
	
	/**
	 * 扩展信息
	 */
	@ManyToOne(cascade={CascadeType.REFRESH},fetch=FetchType.LAZY)
	@JoinColumn(name="AVATAR_ID")
	private PathFile avatar;
	private String region;
	private String address;
	private Gender gender;
	private String email;
	private String qq;
	private String wechat;
	private String blog;
	private String signature;
	private String hobby;
	private String occupation;
	private String mobile;
	private String www;
	
	/**
	 * 安全信息
	 */
	private String safeEmail;
	private String bindPhone;
	private String realName;
	private String idcard;
	@ManyToOne(cascade={CascadeType.REFRESH},fetch=FetchType.LAZY)
	@JoinColumn(name="CARDPHOTO_ID")
	private PathFile cardPhoto;
	private String qqLogin;
	private String wechatLogin;
	private String blogLogin;
	private boolean auth=false;
	
	
	/**
	 * 时间记录
	 */
	private Long createTime;
	private Long lastLoginTime;
	private Long lastChangeTime;
	public String getLoginName() {
		return loginName;
	}
	public void setLoginName(String loginName) {
		this.loginName = loginName;
	}
	public String getNickName() {
		return nickName;
	}
	public void setNickName(String nickName) {
		this.nickName = nickName;
	}
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	public PathFile getAvatar() {
		return avatar;
	}
	public void setAvatar(PathFile avatar) {
		this.avatar = avatar;
	}
	public String getRegion() {
		return region;
	}
	public void setRegion(String region) {
		this.region = region;
	}
	public String getAddress() {
		return address;
	}
	public void setAddress(String address) {
		this.address = address;
	}
	public Gender getGender() {
		return gender;
	}
	public void setGender(Gender gender) {
		this.gender = gender;
	}
	public String getEmail() {
		return email;
	}
	public void setEmail(String email) {
		this.email = email;
	}
	public String getQq() {
		return qq;
	}
	public void setQq(String qq) {
		this.qq = qq;
	}
	public String getWechat() {
		return wechat;
	}
	public void setWechat(String wechat) {
		this.wechat = wechat;
	}
	public String getBlog() {
		return blog;
	}
	public void setBlog(String blog) {
		this.blog = blog;
	}
	public String getSignature() {
		return signature;
	}
	public void setSignature(String signature) {
		this.signature = signature;
	}
	public String getHobby() {
		return hobby;
	}
	public void setHobby(String hobby) {
		this.hobby = hobby;
	}
	public String getOccupation() {
		return occupation;
	}
	public void setOccupation(String occupation) {
		this.occupation = occupation;
	}
	public String getMobile() {
		return mobile;
	}
	public void setMobile(String mobile) {
		this.mobile = mobile;
	}
	public String getWww() {
		return www;
	}
	public void setWww(String www) {
		this.www = www;
	}
	public String getSafeEmail() {
		return safeEmail;
	}
	public void setSafeEmail(String safeEmail) {
		this.safeEmail = safeEmail;
	}
	public String getBindPhone() {
		return bindPhone;
	}
	public void setBindPhone(String bindPhone) {
		this.bindPhone = bindPhone;
	}
	public String getRealName() {
		return realName;
	}
	public void setRealName(String realName) {
		this.realName = realName;
	}
	public String getIdcard() {
		return idcard;
	}
	public void setIdcard(String idcard) {
		this.idcard = idcard;
	}
	public PathFile getCardPhoto() {
		return cardPhoto;
	}
	public void setCardPhoto(PathFile cardPhoto) {
		this.cardPhoto = cardPhoto;
	}
	public String getQqLogin() {
		return qqLogin;
	}
	public void setQqLogin(String qqLogin) {
		this.qqLogin = qqLogin;
	}
	public String getWechatLogin() {
		return wechatLogin;
	}
	public void setWechatLogin(String wechatLogin) {
		this.wechatLogin = wechatLogin;
	}
	public String getBlogLogin() {
		return blogLogin;
	}
	public void setBlogLogin(String blogLogin) {
		this.blogLogin = blogLogin;
	}
	public boolean isAuth() {
		return auth;
	}
	public void setAuth(boolean auth) {
		this.auth = auth;
	}
	public Long getCreateTime() {
		return createTime;
	}
	public void setCreateTime(Long createTime) {
		this.createTime = createTime;
	}
	public Long getLastLoginTime() {
		return lastLoginTime;
	}
	public void setLastLoginTime(Long lastLoginTime) {
		this.lastLoginTime = lastLoginTime;
	}
	public Long getLastChangeTime() {
		return lastChangeTime;
	}
	public void setLastChangeTime(Long lastChangeTime) {
		this.lastChangeTime = lastChangeTime;
	}
	
	
}
